import org.springframework.beans.factory.FactoryBean;

public class BookFactory implements FactoryBean {
    @Override
    public Book getObject() throws Exception{
        Book book = new Book();
        book.setAuthor("mashibing");
        book.setBname("JAVA");
        return  book;
    }
    @Override
    public Class<?> getObjectType(){

        return null;
    }
}
